/*
 * DRACOON API
 * REST Web Services for DRACOON<br><br>This page provides an overview of all available and documented DRACOON APIs, which are grouped by tags.<br>Each tag provides a collection of APIs that are intended for a specific area of the DRACOON.<br><br><a title='Developer Information' href='https://developer.dracoon.com'>Developer Information</a>&emsp;&emsp;<a title='Get SDKs on GitHub' href='https://github.com/dracoon'>Get SDKs on GitHub</a><br><br><a title='Terms of service' href='https://www.dracoon.com/terms/general-terms-and-conditions/'>Terms of service</a>
 *
 * OpenAPI spec version: 4.45.1
 * 
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package ch.cyberduck.core.sds.io.swagger.client.model;

import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.v3.oas.annotations.media.Schema;
import org.joda.time.DateTime;
/**
 * Deleted node information (Deleted node can be a folder or file)
 */
@Schema(description = "Deleted node information (Deleted node can be a folder or file)")

public class DeletedNodeSummary {
  @JsonProperty("parentId")
  private Long parentId = null;

  @JsonProperty("referenceId")
  private Long referenceId = null;

  @JsonProperty("parentPath")
  private String parentPath = null;

  @JsonProperty("name")
  private String name = null;

  /**
   * Node type
   */
  public enum TypeEnum {
    FOLDER("folder"),
    FILE("file");

    private String value;

    TypeEnum(String value) {
      this.value = value;
    }
    @JsonValue
    public String getValue() {
      return value;
    }

    @Override
    public String toString() {
      return String.valueOf(value);
    }
    @JsonCreator
    public static TypeEnum fromValue(String input) {
      for (TypeEnum b : TypeEnum.values()) {
        if (b.value.equals(input)) {
          return b;
        }
      }
      return null;
    }

  }  @JsonProperty("type")
  private TypeEnum type = null;

  @JsonProperty("cntVersions")
  private Integer cntVersions = null;

  @JsonProperty("firstDeletedAt")
  private DateTime firstDeletedAt = null;

  @JsonProperty("lastDeletedAt")
  private DateTime lastDeletedAt = null;

  @JsonProperty("lastDeletedNodeId")
  private Long lastDeletedNodeId = null;

  @JsonProperty("timestampCreation")
  private DateTime timestampCreation = null;

  @JsonProperty("timestampModification")
  private DateTime timestampModification = null;

  public DeletedNodeSummary parentId(Long parentId) {
    this.parentId = parentId;
    return this;
  }

   /**
   * Parent node ID (room or folder)
   * @return parentId
  **/
  @Schema(required = true, description = "Parent node ID (room or folder)")
  public Long getParentId() {
    return parentId;
  }

  public void setParentId(Long parentId) {
    this.parentId = parentId;
  }

  public DeletedNodeSummary referenceId(Long referenceId) {
    this.referenceId = referenceId;
    return this;
  }

   /**
   * &amp;#128640; Since v4.37.0  Reference ID. Identical across all versions of a file
   * @return referenceId
  **/
  @Schema(description = "&#128640; Since v4.37.0  Reference ID. Identical across all versions of a file")
  public Long getReferenceId() {
    return referenceId;
  }

  public void setReferenceId(Long referenceId) {
    this.referenceId = referenceId;
  }

  public DeletedNodeSummary parentPath(String parentPath) {
    this.parentPath = parentPath;
    return this;
  }

   /**
   * Parent node path  &#x60;/&#x60; if node is a root node (room)
   * @return parentPath
  **/
  @Schema(required = true, description = "Parent node path  `/` if node is a root node (room)")
  public String getParentPath() {
    return parentPath;
  }

  public void setParentPath(String parentPath) {
    this.parentPath = parentPath;
  }

  public DeletedNodeSummary name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Node name
   * @return name
  **/
  @Schema(required = true, description = "Node name")
  public String getName() {
    return name;
  }

  public void setName(String name) {
    this.name = name;
  }

  public DeletedNodeSummary type(TypeEnum type) {
    this.type = type;
    return this;
  }

   /**
   * Node type
   * @return type
  **/
  @Schema(required = true, description = "Node type")
  public TypeEnum getType() {
    return type;
  }

  public void setType(TypeEnum type) {
    this.type = type;
  }

  public DeletedNodeSummary cntVersions(Integer cntVersions) {
    this.cntVersions = cntVersions;
    return this;
  }

   /**
   * Number of deleted versions of this file
   * @return cntVersions
  **/
  @Schema(required = true, description = "Number of deleted versions of this file")
  public Integer getCntVersions() {
    return cntVersions;
  }

  public void setCntVersions(Integer cntVersions) {
    this.cntVersions = cntVersions;
  }

  public DeletedNodeSummary firstDeletedAt(DateTime firstDeletedAt) {
    this.firstDeletedAt = firstDeletedAt;
    return this;
  }

   /**
   * First deleted version
   * @return firstDeletedAt
  **/
  @Schema(required = true, description = "First deleted version")
  public DateTime getFirstDeletedAt() {
    return firstDeletedAt;
  }

  public void setFirstDeletedAt(DateTime firstDeletedAt) {
    this.firstDeletedAt = firstDeletedAt;
  }

  public DeletedNodeSummary lastDeletedAt(DateTime lastDeletedAt) {
    this.lastDeletedAt = lastDeletedAt;
    return this;
  }

   /**
   * Last deleted version
   * @return lastDeletedAt
  **/
  @Schema(required = true, description = "Last deleted version")
  public DateTime getLastDeletedAt() {
    return lastDeletedAt;
  }

  public void setLastDeletedAt(DateTime lastDeletedAt) {
    this.lastDeletedAt = lastDeletedAt;
  }

  public DeletedNodeSummary lastDeletedNodeId(Long lastDeletedNodeId) {
    this.lastDeletedNodeId = lastDeletedNodeId;
    return this;
  }

   /**
   * Node ID of last deleted version
   * @return lastDeletedNodeId
  **/
  @Schema(required = true, description = "Node ID of last deleted version")
  public Long getLastDeletedNodeId() {
    return lastDeletedNodeId;
  }

  public void setLastDeletedNodeId(Long lastDeletedNodeId) {
    this.lastDeletedNodeId = lastDeletedNodeId;
  }

  public DeletedNodeSummary timestampCreation(DateTime timestampCreation) {
    this.timestampCreation = timestampCreation;
    return this;
  }

   /**
   * &amp;#128640; Since v4.22.0  Time the node was created on external file system
   * @return timestampCreation
  **/
  @Schema(description = "&#128640; Since v4.22.0  Time the node was created on external file system")
  public DateTime getTimestampCreation() {
    return timestampCreation;
  }

  public void setTimestampCreation(DateTime timestampCreation) {
    this.timestampCreation = timestampCreation;
  }

  public DeletedNodeSummary timestampModification(DateTime timestampModification) {
    this.timestampModification = timestampModification;
    return this;
  }

   /**
   * &amp;#128640; Since v4.22.0  Time the content of a node was last modified on external file system
   * @return timestampModification
  **/
  @Schema(description = "&#128640; Since v4.22.0  Time the content of a node was last modified on external file system")
  public DateTime getTimestampModification() {
    return timestampModification;
  }

  public void setTimestampModification(DateTime timestampModification) {
    this.timestampModification = timestampModification;
  }


  @Override
  public boolean equals(java.lang.Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    DeletedNodeSummary deletedNodeSummary = (DeletedNodeSummary) o;
    return Objects.equals(this.parentId, deletedNodeSummary.parentId) &&
        Objects.equals(this.referenceId, deletedNodeSummary.referenceId) &&
        Objects.equals(this.parentPath, deletedNodeSummary.parentPath) &&
        Objects.equals(this.name, deletedNodeSummary.name) &&
        Objects.equals(this.type, deletedNodeSummary.type) &&
        Objects.equals(this.cntVersions, deletedNodeSummary.cntVersions) &&
        Objects.equals(this.firstDeletedAt, deletedNodeSummary.firstDeletedAt) &&
        Objects.equals(this.lastDeletedAt, deletedNodeSummary.lastDeletedAt) &&
        Objects.equals(this.lastDeletedNodeId, deletedNodeSummary.lastDeletedNodeId) &&
        Objects.equals(this.timestampCreation, deletedNodeSummary.timestampCreation) &&
        Objects.equals(this.timestampModification, deletedNodeSummary.timestampModification);
  }

  @Override
  public int hashCode() {
    return Objects.hash(parentId, referenceId, parentPath, name, type, cntVersions, firstDeletedAt, lastDeletedAt, lastDeletedNodeId, timestampCreation, timestampModification);
  }


  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class DeletedNodeSummary {\n");
    
    sb.append("    parentId: ").append(toIndentedString(parentId)).append("\n");
    sb.append("    referenceId: ").append(toIndentedString(referenceId)).append("\n");
    sb.append("    parentPath: ").append(toIndentedString(parentPath)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    type: ").append(toIndentedString(type)).append("\n");
    sb.append("    cntVersions: ").append(toIndentedString(cntVersions)).append("\n");
    sb.append("    firstDeletedAt: ").append(toIndentedString(firstDeletedAt)).append("\n");
    sb.append("    lastDeletedAt: ").append(toIndentedString(lastDeletedAt)).append("\n");
    sb.append("    lastDeletedNodeId: ").append(toIndentedString(lastDeletedNodeId)).append("\n");
    sb.append("    timestampCreation: ").append(toIndentedString(timestampCreation)).append("\n");
    sb.append("    timestampModification: ").append(toIndentedString(timestampModification)).append("\n");
    sb.append("}");
    return sb.toString();
  }

  /**
   * Convert the given object to string with each line indented by 4 spaces
   * (except the first line).
   */
  private String toIndentedString(java.lang.Object o) {
    if (o == null) {
      return "null";
    }
    return o.toString().replace("\n", "\n    ");
  }

}
